/**
 * 
 */
package de.midnightdance.client.ui.composites;

import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Table;
import org.eclipse.swt.widgets.TableColumn;

/**
 * @author Surfer
 *
 */
public class CompositeEPAntraege extends Composite {
	private Table tableEpAntraege;

	public CompositeEPAntraege(Composite parent, int style) {
		super(parent, style);		
		setLayout(new GridLayout(1, false));
		
		tableEpAntraege = new Table(this, SWT.BORDER | SWT.FULL_SELECTION);
		tableEpAntraege.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 1, 1));
		tableEpAntraege.setHeaderVisible(true);
		tableEpAntraege.setLinesVisible(true);	
			TableColumn tblclmnDatum = new TableColumn(tableEpAntraege, SWT.NONE);
			tblclmnDatum.setWidth(100);
			tblclmnDatum.setText("Datum");			
			TableColumn tblclmnEp = new TableColumn(tableEpAntraege, SWT.NONE);
			tblclmnEp.setWidth(100);
			tblclmnEp.setText("EP");
			TableColumn tblclmnNotizen = new TableColumn(tableEpAntraege, SWT.NONE);
			tblclmnNotizen.setWidth(100);
			tblclmnNotizen.setText("Notizen");
	}
	
//	private void fillTable(List<EpAntrag> antraege){
//		for (EpAntrag epAntrag : antraege) {
//			TableItem item = new TableItem(tableEpAntraege, SWT.NONE);
//			item.setText(0, epAntrag.getDatum().toString());
//			item.setText(1, epAntrag.getEpGegeben()+"");
//			item.setText(2, epAntrag.getKommentar());
//		}		
//	}
//	
//	public void setEpAntraege(List<EpAntrag> epAntraege){
//		fillTable(epAntraege);
//	}
}
